{* Load fancy box and sliding panel *}
<link rel="stylesheet" type="text/css" href="{$smarty.const.THEME_RELATIVE}modules/searchmodule/slidingpanel.css" />
<div class="searchmodule search_results">
    <img src="{$smarty.const.THEME_RELATIVE}modules/searchmodule/images/16.png" border=0 align=left class="img_search_result" > 
    <h1 style="font-size: 30px;">{$_TR.search_result}</h1>
    <table width="100%" border=0 valign=top>
        <tr valign=middle> 
            <td>
                <span class="searched_for">
                    {$_TR.search_returned|sprintf:$query:$num_results} <span style="color: #C0C0C0; ">- ({$query_time}s)</span><br />
                    {if $have_excluded_terms != 0}{$_TR.ignored_terms}:&nbsp;&nbsp;<span class="search_results_excludes">{', '|join:$excluded_terms}</span>{/if}
                </span> 
    {* Sliding Panel *}
    <!--
    <div class="slidingpanel">
    <div id="container"> 
    <div id="topPanel"> 
    <div id="panel"> 
    <div id="pnlContent"> 
    {include file="`$smarty.const.BASE`themes/coolwatertheme/modules/searchmodule/views/_advance.tpl"}                	                    
    </div> 
    </div> 
    </div> 
    </div>
    </div>-->
    {* end of Sliding Panel *}
    </td>
    <td align=center width=10% valign=top >
    <!--<span class="query_time">{$query_time}s</span> -->
    <!--<div class="slidingpanel">
    <div class="panelBtn" id="openBtn"><a href="#" title="{$_TR.open_configure}"><img src="{$smarty.const.THEME_RELATIVE}images/plus_circle.png" alt="{$_TR.open_configure}" /><br>{$_TR.open_configure}</a></div> 
    <div class="panelBtn" id="closeBtn" style="display: none;"><a href="#" title="{$_TR.close_configure}"><img src="{$smarty.const.THEME_RELATIVE}images/minus_circle.png" alt="{$_TR.close_configure}" /><br>{$_TR.close_configure}</a></div>
    </div>-->
    </td>
    </tr>
    </table>
    {* Sliding panel *}
    {literal}
    <script type="text/javascript"> 
    $(document).ready(function() {
    if ($.browser.msie)
    $("#topPanel").css("left",150);
    $("#closeBtn").click(function(){
    $("#panel").animate({height: "130px"}, "fade").animate({height: "0px"}, "fast");
    $(".panelBtn").toggle();
    return false;
    });
    $("#openBtn").click(function(){
    $("#panel").animate({height: "0px"}, "fade").animate({height: "110px"}, "medium");
    $(".panelBtn").toggle();
    return false;
    });
    });
    </script> 
    {/literal}
    {* End of Sliding panel *}

    {if $config->is_categorized == 0}
    {foreach from=$results item=result}
    <div class="item {cycle values="odd,even"}">
    {if $result->no_title == 0}
    <h3>
    <a href="{$result->view_link}">{$result->title}</a>
    </h3>
    {/if}
    {* 8/26/2009 add section reverse *}
    <div class="section">
        {foreach from=$result->sections item=section}
        <a href="{$section->url}">{$section->name}</a>
        {if $result->main_section !== $section->id}
        &nbsp;>
        {/if}
        {/foreach}
    </div>
    {* end of 8/26/2009*}
    {if $result->sum != ""}
    <div class="summary">{$result->sum}</div>{/if}
    {*if $result->view_link != ""}<div class="search_result_item_link">{$result->view_link}</div>{/if*}
		</div>
	{/foreach}
{else}{* categorized, list of crap is two levels deep *}
	{foreach from=$results key=category item=subresults}
		<h2><a name="#{$category}">{$category} matching "{$query}":</a></h2>
		{foreach from=$subresults item=result}
			<div class="item {cycle values="odd,even"}">
				<a href="{$result->view_link}">{$result->title}</a>
				{if $result->sum != ""}<br /><span class="summary">{$result->sum}</span>{/if}
				{*<br /><span class="search_result_item_link">{$result->view_link}</span>*}
			</div>
		{/foreach}
	{/foreach}
{/if}
</div>
<div align=center>{paging current_page=$page pages=$pages search_string=$query action=search module=searchmodule page_length=4}</div>



